import 'dart:ui';

import 'package:flutter/material.dart';

import 'HexColor.dart';

class ImConstant {

  static const TENANT_CODE = '0002';
  static const MESSAGE_SPLIT = 'm-';
  static const IM_SESSION_SHOW_DAYS = 14;

  static const MESSAGE_TYPE_PREFIX = '￼';

  static const int SESSION_MAX_SIZE = 1000;

  static const String IM_LOGIN_USER = "Im_Login_User";

  static const double IM_DEFAULT_SIZE = 14;
  static const double IM_SMALL_SIZE = 11;
  static const double IM_USER_ICON_SIZE = 50;
  static const double IM_APP_BAR_HEIGTH = 40;
  static const int IM_GROUP_DESCRIPTION_LENGTH = 130;
  static const int IM_GROUP_NAME_LENGTH = 40;
  static const int IM_USER_NAME_LENGTH = 16;

  static const Color IM_TEXT_COLOR =  Colors.black;
  static Color IM_MAIN_BACKGROUND_COLOR = HexColor.fromHex("#EDEDED");
  static Color IM_BORDER_COLOR = Colors.grey.shade300;
  static const Color IM_RESERVE_BACKGROUND_COLOR = Colors.white;

  static Color IM_LIST_GROUP_COLOR = HexColor.fromHex("#EfEfEf");

  // todo 当前是测试值
  static const int MESSAGE_LIST_MAX_SIZE = 30;
  static const int MESSAGE_LIST_DEFAULT_SIZE = 20;
  static const int MESSAGE_LIST_NEXT_SIZE = 20;
  static const Color MESSAGE_RECEIVE_COLOR = Colors.white;
  static Color MESSAGE_SEND_COLOR = HexColor.fromHex('#95EC69');

  // 消息展示最大宽度
  static const double MESSAGE_MAX_WIDTH = 250;

  static Color IM_LOGIN_DEFAULT_COLOR = HexColor.fromHex("#87cefa");
  static const double IM_LOGIN_TYPE_ICON_SIZE = 30;

  // 初始滑屏密码次数
  static const IM_INIT_PATTERN_LOCK_NUM = 3;
  static const IM_PATTERN_LOCK_SETTING = 'IM_PATTERN_LOCK_SETTING';
  static const IM_PATTERN_LOCK_PASSWORD = 'IM_PATTERN_LOCK_PASSWORD';
  static const IM_PATTERN_LOCK_USERID = 'IM_PATTERN_LOCK_USERID';

  static const int Message_FileSendTime = 5;

  // 文件上传每次大小
  static const FILE_UPLOAD_P_SIZE = 1024;
  // 文件下载ByteBuf 大小
  static const FILE_DOWLOAD_P_SIZE = 1024;

  static const MESSAGE_IMAGE_FIT_MAX_WIDTH = 120;
  static const MESSAGE_IMAGE_FIT_MAX_HEGITH = 160;

  static const WEBRTC_USER_LIMIT = 7;          // WebRtc 多人视频最大人数限制

}